Skip to content

Conversation

@olivierwilkinson
Copy link
Owner

Currently there are two scenarios when a select action type is found:

  • When an include has a select within it
  • When a select has a relation in it

This means that there is a situation where it is not possible to reason about what to do with a select because the two scenarios look the same based on the available information; both have the include action as the parent.

BREAKING CHANGE: remove the calls for include selects

Middleware that relied on calls with the "select" action for select objects within an include will no longer be able to use that call. Instead use the parent "include" action to modify the selected fields, or use the "select" action for the relation within that select object.

Currently there are two scenarios when a select action type is found:
- When an include has a select within it
- When a select has a relation in it

This means that there is a situation where it is not possible to reason
about what to do with a select because the two scenarios look the same
based on the available information; both have the include action as the
parent.

BREAKING CHANGE: remove the calls for include selects

Middleware that relied on calls with the "select" action for select
objects within an include will no longer be able to use that call.
Instead use the parent "include" action to modify the selected fields,
or use the "select" action for the relation within that select object.
@olivierwilkinson olivierwilkinson force-pushed the improve-rationality-of-calls-by-removing-include-select-calls branch from 50f62ad to ad433d1 Compare January 13, 2024 13:45
@olivierwilkinson olivierwilkinson merged commit 36c5410 into main Jan 13, 2024
@github-actions
Copy link

🎉 This PR is included in version 4.0.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants